package com.dwxt.mall.admin.service.feign;

import com.dwxt.common.base.BaseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "cmsback")
public interface AdminUserService {

    /*@RequestMapping("/admin/user/create")
    public BaseResult createOrUpdateUser(@RequestParam String username, @RequestParam String phone, @RequestParam String password,
                             @RequestParam Integer type, @RequestParam List<Integer> roleIds);*/

    //新增或修改用户信息
    @RequestMapping("/admin/user/createOrUpdateUser")
    public BaseResult createOrUpdateUser(@RequestParam Integer id, @RequestParam String username, @RequestParam String phone,
                                         @RequestParam String password, @RequestParam Integer type,
                                         @RequestParam List<Integer> roleIds);

    //查询现登录的用户信息
    @RequestMapping("/admin/user/selectUser")
    public BaseResult selectUser();

    //查询所有的商家用户信息
    @RequestMapping("/admin/user/selectAllMallUser")
    public BaseResult selectAllMallUser(@RequestParam Integer type);

}
